package com.cskaoyan.controller.wx;

import com.cskaoyan.bean.BaseRespVo;
import com.cskaoyan.bean.bo.GoodsBrandListBo;
import com.cskaoyan.bean.pojo.MarketBrand;
import com.cskaoyan.bean.vo.GoodsBrandListVo;
import com.cskaoyan.service.GoodsBrandService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author :LuoXuXin
 * @date :Created in 2022/4/8   20:20
 * @version : $version
 * @description:
 * @return:
 */
@RestController
@RequestMapping("wx/brand")
public class GoodsBrandController {

    @Autowired
    GoodsBrandService goodsBrandService;

    @GetMapping("list")
    public BaseRespVo goodsBrandList(GoodsBrandListBo goodsBrandListBo) {
        GoodsBrandListVo goodsBrandListVo = goodsBrandService.goodsBrandList(goodsBrandListBo);
        return BaseRespVo.ok(goodsBrandListVo);
    }


    @GetMapping("detail")
    public BaseRespVo goodsBrandDetail(Integer id) {
        MarketBrand marketBrand = goodsBrandService.goodsBrandDetail(id);
        return BaseRespVo.ok(marketBrand);
    }

}
